<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>打开一个大型对象</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.pg-lo-import.html">pg_lo_import</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.pg-lo-read-all.html">pg_lo_read_all</a></div>
 <div class="up"><a href="ref.pgsql.html">PostgreSQL 函数</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="function.pg-lo-open" class="refentry">
   <div class="refnamediv">
    <h1 class="refname">pg_lo_open</h1>
    <p class="verinfo">(PHP 4 &gt;= 4.2.0, PHP 5)</p><p class="refpurpose"><span class="refname">pg_lo_open</span> &mdash; <span class="dc-title">打开一个大型对象</span></p>

   </div>
   <div class="refsect1 unknown-seealsp" id="refsect1-function.pg-lo-open-unknown-seealsp">
    <h3 class="title">说明</h3>
     <div class="methodsynopsis dc-description">
      <span class="type">resource</span> <span class="methodname"><strong>pg_lo_open</strong></span>
       ( <span class="methodparam"><span class="type">resource</span> <code class="parameter">$connection</code></span>
      , <span class="methodparam"><span class="type">int</span> <code class="parameter">$oid</code></span>
      , <span class="methodparam"><span class="type">string</span> <code class="parameter">$mode</code></span>
      )</div>

    <p class="para rdfs-comment">
     <span class="function"><strong>pg_lo_open()</strong></span> 打开一个大型对象并返回大型对象资源号。该资源号内封装了连接号。<em><code class="parameter">oid</code></em> 指定了有效的大型对象的 oid，<em><code class="parameter">mode</code></em> 可以为 &quot;r&quot;，&quot;w&quot; 或者 &quot;rw&quot;。如果失败则返回 <strong><code>FALSE</code></strong>。
    </p>
    <div class="warning"><strong class="warning">Warning</strong>
     <p class="para">
      在关闭大型对象资源之前不要关闭数据库连接。
     </p>
    </div>
    <p class="para">
     要使用大型对象（lo）接口，需要将其放置在事务块中。
    </p>
    <blockquote class="note"><p><strong class="note">Note</strong>: 
     <p class="para">
      本函数以前的名字为 <em>pg_loopen()</em>。
     </p>
    </p></blockquote>
    <p class="para">
     参见 <span class="function"><a href="function.pg-lo-close.html" class="function">pg_lo_close()</a></span> 和 <span class="function"><a href="function.pg-lo-create.html" class="function">pg_lo_create()</a></span>。
    </p>
   </div>

  </div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.pg-lo-import.html">pg_lo_import</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.pg-lo-read-all.html">pg_lo_read_all</a></div>
 <div class="up"><a href="ref.pgsql.html">PostgreSQL 函数</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>
